import './assets/main.css';
import { createApp } from 'vue';
import App from './App.vue';
// 导入ElementPlus插件
import ElementPlus from 'element-plus';
import 'element-plus/dist/index.css';
//导入router
import router from './router';
//导入pinia
import { createPinia } from 'pinia';
import axios from 'axios';
//引入echarts
import VueEcharts from 'vue-echarts';
import 'echarts';

import drag from 'v-drag';

// 配置 axios 全局携带 cookie
axios.defaults.withCredentials = true;

const app = createApp(App);
// 注册插件
app.component('v-chart', VueEcharts);
app.use(ElementPlus);
app.use(router);
app.use(createPinia());
app.mount('#app');
app.use(drag);
